home *** CD-ROM | disk | FTP | other *** search
/ Delphi Developer's Kit 1996 / Delphi Developer's Kit 1996.iso / power / sockv2 / fileput.pas < prev    next >
Pascal/Delphi Source File  |  1995-12-22  |  1KB  |  55 lines

  1. unit Fileput;
  2.  
  3. interface
  4.  
  5. uses WinTypes, WinProcs, Classes, Graphics, Forms, Controls, Buttons,
  6.   StdCtrls, ExtCtrls, Dialogs;
  7.  
  8. type
  9.   TPutDLG = class(TForm)
  10.     Bevel1: TBevel;
  11.     OKBtn: TBitBtn;
  12.     CancelBtn: TBitBtn;
  13.     Label1: TLabel;
  14.     FileName: TEdit;
  15.     GroupBox1: TGroupBox;
  16.     rbASCII: TRadioButton;
  17.     rbBINARY: TRadioButton;
  18.     rbEBCDIC: TRadioButton;
  19.     Label2: TLabel;
  20.     RemoteName: TEdit;
  21.     Browse: TButton;
  22.     OpenDialog1: TOpenDialog;
  23.     procedure FormCreate(Sender: TObject);
  24.     procedure BrowseClick(Sender: TObject);
  25.   private
  26.     { Private declarations }
  27.   public
  28.     { Public declarations }
  29.   end;
  30.  
  31. var
  32.   PutDLG: TPutDLG;
  33.  
  34. implementation
  35.  
  36. {$R *.DFM}
  37.  
  38. procedure TPutDLG.FormCreate(Sender: TObject);
  39. begin
  40.   rbASCII.Checked := True;
  41. end;
  42.  
  43. procedure TPutDLG.BrowseClick(Sender: TObject);
  44. begin
  45.   OpenDialog1.Options := [ofFileMustExist];
  46.   OpenDialog1.Filter := 'All files (*.*)|*.*';
  47.   if OpenDialog1.Execute then
  48.   begin
  49.     FileName.Text := OpenDialog1.Filename;
  50.     RemoteName.SetFocus;
  51.   end;
  52. end;
  53.  
  54. end.
  55.